package xuecheng.tool.nosql.mongo.entity;

import java.io.Serializable;

import org.springframework.data.annotation.Id;
import org.springframework.data.annotation.Transient;
import org.springframework.data.mongodb.core.mapping.TextScore;

import lombok.Data;

/**
 * mongo 数据实体基类
 *
 * @author PengXueCheng
 * @version 1.0.0
 **/
@Data
public class BaseEntity implements Serializable {

    /**
     * 主键
     */
    @Id
    protected String id;

    /**
     * 全文搜素得分
     */
    @TextScore
    @Transient
    protected Double score;

}
